package com.edu.service.food;

import com.edu.entity.Food;
import com.edu.utils.PageList;
import com.edu.utils.PageParam;

import java.sql.SQLException;
import java.util.List;

/**
 * @author ZCN
 * @version 1.0
 * @date 2021/11/19 14:57
 */
public interface FoodService {
    // 分页数据
    PageList pageList(PageParam pageParam) throws Exception;
    // 查询所有
    List<Food> findAll() throws SQLException;

    List<Food> todayRecommend() throws SQLException;

    List<Food> hotsFoods() throws SQLException;
    List<Food> cookRecommend() throws SQLException;

    List<Food> hotsFoodsCom() throws SQLException;

    List<Food> cookRecommendComplex() throws SQLException;

    Food findOne(Integer id) throws SQLException;

    // 修改
    void update(Food food) throws SQLException;

    // 下架
    void delete(Integer id) throws SQLException;

    // 上架
    void online(Integer id) throws SQLException;

    // 添加
    void insert(Food food) throws SQLException;
}
